<!DOCTYPE html>
<html>

<head>
    <meta charset="utf-8">
    <title>IT服务知识库</title>
    <!--公用样式-->
    <link rel="stylesheet" type="text/css" href="${re.contextPath}/plugin/common/css/comment.css"/>
    <!--页面样式-->
    <link rel="stylesheet" type="text/css" href="${re.contextPath}/plugin/it/common/css/style.css" />
    <!--Layui-->
    <link rel="stylesheet" href="${re.contextPath}/plugin/layui/css/layui.css" media="all"/>
    <style>
        .break {
            width: 76%;
            word-break: break-all;
        }
        .pt2px{
            padding-top: 2px;
        }
    </style>
</head>

<body>
<!--容器-->
<div class="container  clearfix"  style="margin-left:3%;width:97%;">
    <!--占位-->
    <!--			<div class="headerHightAdd"></div>-->
    <div class="itDetaBtn mt20 clearfix">
        <#if "${qx}"=="1">
        <button type="button" id="download" class="fl bluebg white">下载</button>
        </#if>
        <@shiro.hasPermission name ="it:redact">
            <#if ('${fileIsForm}' == '2' && '${selectFile.linkId}' != '')>
                <button type="button" class="fl bluebg white" onclick="_itkl.form.showEdit('${selectFile.id}')">编辑表单</button>
            </#if>
        </@shiro.hasPermission>
        <@shiro.hasPermission name ="it:move">
        <button type="button" id="move" class="fl greenbg white">移动</button>
        </@shiro.hasPermission>
        <@shiro.hasPermission name ="it:delete">
        <button type="button" id="del" class="fl redbg white">删除</button>
        </@shiro.hasPermission>
        <@shiro.hasPermission name ="it:searching">
        <button type="button" id="searching" class="fl greenbg white">检索设置</button>
        </@shiro.hasPermission>
        <#if '${selectFile.fileCollect}'=='0'>
            <button type="button" state="0" id="collect" class="fl bluebg white">收藏</button>
         <#elseif '${selectFile.fileCollect}'=='1'>
             <button type="button" state="1" id="collect" class="fl greenbg white">取消收藏</button>
        </#if>
    </div>
    <div class="itDeta clearfix">
        <div class="itDetaLf itDetaLf1 whitebg fl">
            <div class="ft20 bold clearfix">
                <label class="fl">文件名称：</label>
                <span id="fileName" fileName="${selectFile.fileName}" class="fl">${selectFile.fileName}</span>
                <button type="button" id="open" class="bluebg white bor0 fr">打开文件</button>
            </div>
            <input type="hidden" id="id" value="${selectFile.id}">
            <ul>
                <li class="clearfix">
                    <label class="gary fl">创建者：</label>
                    <span class="fl pt2px">${selectFile.createBy}</span>
                </li>
                <li class="clearfix">
                    <label class="gary fl">创建时间：</label>
                    <span class="fl pt2px">${selectFile.createDate?string("yyyy-MM-dd hh:mm")}</span>
                </li>
                <li class="clearfix">
                    <label class="gary fl">文档编号：</label>
                    <span class="fl break pt2px">${selectFile.fileNumber}</span>
                </li>
                <li class="clearfix">
                    <label class="gary fl">文档路径：</label>
                    <span class="fl w80p break">${thisFilePath}</span>
                </li>
                <li class="clearfix">
                    <label class="gary fl">关键字：</label>
                    <span class="fl break">${selectFile.searchKey}</span>
                </li>
                <li class="clearfix">
                    <label class="gary fl">说明：</label>
                    <span class="fl break">${selectFile.remark}</span>
                </li>
            </ul>
        </div>
        <div class="itDetaFr itDetaFr1 whitebg fr">
            <div class="ft20 bold">相关文档</div>
            <ul>
                <#if "${state}"=="1">
                    <#list file as related>
                    <li>
                        <div>${related.fileName}</div>
                        <button type="button" url="${related.url}" previewId="${related.id}" onclick="preview(this)">预览</button>
                    </li>
                   </#list>
                <#elseif "${state}"=="0">
                    <li>
                        <div>暂无相关文件</div>
                    </li>
                </#if>
            </ul>
        </div>
    </div>
</div>
<!--JQ-->
<script type="text/javascript" charset="utf-8" src="${re.contextPath}/plugin/common/js/jquery-1.8.3.min.js"></script>
<script type="text/javascript" charset="utf-8" src="${re.contextPath}/plugin/common/js/tabs.js"></script>
<!--公用样式JS-->
<script type="text/javascript" charset="utf-8" src="${re.contextPath}/plugin/common/js/comment.js"></script>
<script type="text/javascript" charset="utf-8" src="${re.contextPath}/plugin/tools/tool.js"></script>
<script type="text/javascript" src="${re.contextPath}/plugin/layui/layui.all.js" charset="utf-8"></script>
<script type="text/javascript" src="${re.contextPath}/pageoffice.js" id="po_js_main"></script>
<script type="text/javascript"  charset="utf-8" src="/plugin/it/common/js/itkl.js"></script>
<script type="text/javascript" charset="utf-8" src="/plugin/it/common/js/details.js"></script>
<!--选择城市js-->
<script type="text/javascript" charset="utf-8" src="${re.contextPath}/plugin/common/js/area.js"></script>
<script type="text/javascript" charset="utf-8" src="${re.contextPath}/plugin/common/js/select.js"></script>
<!--进度条-->
<script type="text/javascript" charset="utf-8" src="${re.contextPath}/plugin/common/js/progress.js"></script>
<!--分页-->
<script type="text/javascript" charset="utf-8" src="${re.contextPath}/plugin/common/js/jquery.page.js"></script>

</body>
<script>
    $(function(){
        $(document).parents('iframe').attr('scrolling','no');
        $(".itDeta").css({
            left: $(".Left").width() + 'px',
            top: $(".headerHightAdd").height() + 'px',
            height: ($(document).height() - $(".headerHightAdd").height()) + 'px'
        });
    })
    function flushPage(){
        location.reload();
    }
</script>

</html>
